# name : gsDesign nSurvival
# key : gsDesign.nSurvival
# expand-env: ((yas-indent-line 'fixed) (yas-wrap-around-region 'nil))
# contributor: Shuguang Sun
# --
nSurvival(
  # Lachin and Foulkes (1986)
  lambda1 = ${1:log(2) / 1},  # Control failure rate
  lambda2 = ${2:log(2) / 1},  # Treatment failure rate
  Ts = ${3:24},  # maximum study duration
  Tr = ${4:12},  # accrual (recruitment) duration
  eta = ${5:0},  # equal dropout hazard rate
  ratio = ${6:1}, # Exp/Control
  alpha = ${7:0.025},
  beta = ${8:0.1},
  sided = 1,
  approx = FALSE,  # for rd
  type = "rr",     # hazard ratio
  entry = "unif",
  gamma = NA       # rate parameter for exponential entry
)
